<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<!--  -->
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
      xmlns:p="http://primefaces.org/ui">
    
    <h:body>
        
        
        <div id="main_header">
            
            <div id="website_title">
                <h:link outcome="#{userBean.homePageLink}">
                    <h:graphicImage library="images" name="logo.png" height="50px"/>
                </h:link>
            </div>
            
            <div id="header_options">
                <span>
                    <c:choose>
                        <c:when test="#{userBean.isLogged()}">
                            <h:form>
                                <p:commandButton action="#{loginBean.logout()}" value="Logout [#{userBean.name}]"/>
                            </h:form>
                        </c:when>
                        <c:otherwise>
                            <p:button outcome="registration" value="Register"/>
                        </c:otherwise>
                    </c:choose>
                </span>
            </div>
        
        </div>
        
        
        
    </h:body>


</html>